﻿using Core.Info;
using Core.Utility.Helper;
using NPOI.SS.Formula.Functions;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Core.Utility.Security
{
    /// <summary>
    /// Api签名安全信息
    /// </summary>
    public class ApiSignatureSecurityDataInfo:ApiSignatureInfo
    {
        private string? dataSignature;

        /// <summary>
        /// 数据签名
        /// </summary>
        public string? DataSignature
        {
            get => dataSignature;
            private set => dataSignature = value;
        }

        /// <summary>
        /// 设置数据签名字符串
        /// </summary>
        /// <param name="dataSignature"></param>
        public void SetDataSignature(string? dataSignature)
        {
            DataSignature = dataSignature;
        }

        private string? data;

        /// <summary>
        /// 数据内容,加密时为加密的数据内容，解密时为解密的数据内容
        /// </summary>
        public string? Data
        {
            get => data;
            private set => data = value;
        }

        /// <summary>
        /// 设置数据内容字符串,加密时为加密的数据内容，解密时为解密的数据内容
        /// </summary>
        /// <param name="data"></param>
        public void SetData(string? data)
        {
            Data = data;
        }
    }
}
